import axios from "../../model/axios";
import api from "../../model/api"

export const MetroApi = () => axios({ url: api.metro.banner, method: 'get' })
export const MetroFeedbackApi = (data) => axios({
    method: 'post',
    url: api.metro.addfeedback,
    data,
    headers: { "Authorization": window.localStorage.getItem('token') }
})
export const SearchFeedbackApi = (params) => axios({
    method: 'get',
    url: api.metro.searchfeedback,
    params,
    headers: { "Authorization": window.localStorage.getItem('token') }
})
export const DetailFeedbackApi = (id) => axios({
    method: 'get',
    url: api.metro.detailfeedback + '/' + id,
    params: { id },
    headers: { "Authorization": window.localStorage.getItem('token') }
})
export const PressCategoryApi = () => axios({
    method: 'get',
    url: api.metro.presscategory
})
export const PressCommentListApi = (params) => axios({
    method: 'get',
    url: api.metro.presscommentlist,
    params
})
export const PressPressListApi = (params) => axios({
    method: 'get',
    url: api.metro.presspressList,
    params
})
export const PressPressDetailApi = (id) => axios({
    method: 'get',
    url: api.metro.presspressDetail + '/' + id,
    params: { id }
})
export const CardMessageApi = () => axios({
    method: 'get',
    url: api.metro.cardmessage,
    headers: { "Authorization": window.localStorage.getItem('token') }
})
export const CardReceiveApi = (data) => axios({
    method: 'post',
    url: api.metro.cardreceive,
    data,
    headers: { " Authorization": window.localStorage.getItem('token') }
})
export const CardDeleteApi = (id) => axios({
    method: 'delete',
    url: api.metro.carddelete + '/' + id,
    data: { id },
    headers: { " Authorization": window.localStorage.getItem('token') }
})
export const NoticeListApi = () => axios({
    method: 'get',
    url: api.metro.noticelist,
})
export const NoticeDetailApi = (id) => axios({
    method: 'get',
    url: api.metro.noticedetail + '/' + id,
    params: { id }
})
export const NoticeTitleApi = (params) => axios({
    method: 'get',
    url: api.metro.noticetitle,
    params
})
export const FoundListApi = () => axios({
    method: 'get',
    url: api.metro.foundlist,
})
export const FoundDetailApi = (id) => axios({
    method: 'get',
    url: api.metro.founddetail + '/' + id,
    params: { id }
})
export const CityImgApi = () => axios({
    method: 'get',
    url: api.metro.cityimg,
})
export const CityListApi = () => axios({
    method: 'get',
    url: api.metro.citylist,
})
export const CityStepListApi = (params) => axios({
    method: 'get',
    url: api.metro.citysteplist,
    params
})
export const CityDetailApi = (id) => axios({
    method: 'get',
    url: api.metro.citydetail + id,
    params: { id }
})
export const RecordListApi = () => axios({
    method: 'get',
    url: api.metro.recordlist,
    headers: { "Authorization": window.localStorage.getItem('token') }
})